import ajax from "./ajax"

//购买彩票(幸运飞艇)
export const buyApi = ({one,two,three,four,five,six="",seven="",eight="",nine="",ten="",times,ISSUE,money,type}) => ajax("/my/buy","POST",{one,two,three,four,five,six,seven,eight,nine,ten,times,ISSUE,money,type});

//个人中心
export const getCenter = () => ajax("/my/center","POST");

//充值
//money金额 way方式：alipay,weChat,bank
export const addMoney = ({money,way,remarkCode}) => ajax("/my/addMoney","POST",{money,way,remarkCode});

//提现
//money,way,classify(种类，第一个钱包和第三个钱包可以，给我传1或者3),account账号,truename姓名,bankBranch支行,bankName开户行
export const withdraw = ({money,way,classify,remarkCode,bankId,withdrawPassword}) => ajax("/my/withdraw","POST",{money,way,classify,remarkCode,bankId,withdrawPassword});

//修改密码
export const updatePassword = ({oldPassword,password}) => ajax("/my/updatePassword","POST",{oldPassword,password});

//修改提现密码
export const updateWithdrawPassword = ({oldPassword,password}) => ajax("/my/updateWithdrawPassword","POST",{oldPassword,password});

//第一个钱包转第二个钱包
export const centerToBet = money => ajax("/my/centerToBet","POST",{money});

//第二个钱包转第1个钱包
export const betToCenter = money => ajax("/my/betToCenter","POST",{money});
//第四个钱包转第2个钱包
export const incomeToBet = money => ajax("/my/incomeToBet","POST",{money});
//盈利钱包转充值钱包
export const profitToCenter = money => ajax("/my/profitToCenter","POST",{money});
//复投金额转消费钱包
export const repeatedBetToBet = money => ajax("/my/repeatedBetToBet","POST",{money});
//盈利钱包转消费钱包
export const profitToBet = money => ajax("/my/profitToBet","POST",{money});

//投注记录
export const myTicketRecord = ({num=10,page=1}) => ajax("/my/myTicketRecord","POST",{num,page});

//账变记录
//返回pageNum就是返回的总页数，record就是数组记录
export const moneyRecord = ({num=10,page=1}) => ajax("/my/moneyRecord","POST",{num,page});

//充值记录
//返回pageNum就是返回的总页数，record就是数组记录
export const addMoneyRecord = ({num=10,page=1}) => ajax("/my/addMoneyRecord","POST",{num,page});

//充值账号
export const findPayCodeById = (id) => ajax("/my/findPayCodeById","POST",{id});

//我已充值
export const okPay = (id) => ajax("/my/okPay","POST",{id});

//提现记录
//返回pageNum就是返回的总页数，record就是数组记录
export const withdrawRecord = ({num=10,page=1}) => ajax("/my/withdrawRecord","POST",{num,page});

//确认收款
export const okReceive = (id) => ajax("/my/okReceive","POST",{id});

//充值随机码
export const addMoneyRemarkCodeGet = () => ajax("/my/addMoneyRemarkCodeGet","POST")

//提现随机码
export const withdrawRemarkCodeGet = () => ajax("/my/withdrawRemarkCodeGet","POST")

//vip等级
export const allLevel = () => ajax("/my/allLevel","POST")

//注册
//返回200
export const registApi = ({parentId,username,password}) => ajax("/my/regist","POST",{parentId,username,password});

//团队
export const team = () => ajax("/my/team","POST")
//开启团队亏损分红
export const openTeamSend = ({userid,businessPer}) => ajax("/my/openTeamSend","POST",{userid,businessPer})

//银行卡列表
export const findBanksByUser = () => ajax("/my/findBanksByUser","POST")
//增加银行卡
export const addBank = data => ajax("/my/addBank","POST",data)

//撤销投注
export const recallMyTicket = id => ajax("/my/recallMyTicket","POST",{id})

//退出登陆
export const exit = () => ajax("/my/exit","POST")

//当日结算
export const secondSettlementTeam = ()=>ajax("/my/secondSettlementTeam","POST")

//结算
export const settlement = ()=>ajax("/my/settlement","POST")